import request from '@/utils/request'

export default{
    //获取所有
    getAll(){
        return request({
            url:"/eduservice/edu-teacher/list",
            method:"get"
        })
    },
    //获取分页数据
    getList(page,limit,teacherQuery){
        return request({
            url: `/eduservice/edu-teacher/pageList/${page}/${limit}`,
            method: 'post',
            data: teacherQuery
          })
    },
    //删除
    deleteTeacher(id){
        return request({
            url:`/eduservice/edu-teacher/delete/${id}`,
            method:"delete",
        })
    },
    //获取一条数据
    info(id){
        return request({
            url:`/eduservice/edu-teacher/info/${id}`,
            method:"get",
        })
    },
    //保存
    save(teacher){
        return request({
            url:`/eduservice/edu-teacher/save`,
            method:"post",
            data:teacher
        })
    },
    //更新
    update(teacher){
        return request({
            url:`/eduservice/edu-teacher/update`,
            method:"put",
            data:teacher
        })
    }

}